/**  
* @Title: MtonsVideoVO.java
* @Package cn.net.mtons.weixin.reply.vo
* @Description: TODO
* @author ma jinjian  
* @date 2016年2月7日 下午3:24:42
* @version V1.0  
*/ 
package cn.net.mtons.weixin.rpl.vo;

import java.util.HashMap;
import java.util.Map;

import cn.net.mtons.weixin.MtonsBasicVO;
import cn.net.mtons.weixin.utils.MtonsMessageUtil;

/**
 * @ClassName: MtonsVideoVO
 * @Description: TODO
 * @author ma jinjian
 * @date 2016年2月7日 下午3:24:42
 *
 */
public class MtonsVideoVO extends MtonsBasicVO {

	private String msgType;
	
	private String title;
	
	private String description;
	
	private String mediaId;

	public String getMsgType() {
		return msgType;
	}

	public void setMsgType(String msgType) {
		this.msgType = msgType;
	}

	public String getTitle() {
		return title;
	}

	public void setTitle(String title) {
		this.title = title;
	}

	public String getDescription() {
		return description;
	}

	public void setDescription(String description) {
		this.description = description;
	}

	public String getMediaId() {
		return mediaId;
	}

	public void setMediaId(String mediaId) {
		this.mediaId = mediaId;
	}

	@Override
	public String toString() {
		return "MtonsVideoVO [msgType=" + msgType + ", mediaId=" + mediaId
				+ "]";
	}

	@Override
	public String toXml() {
		MtonsMessageUtil util = new MtonsMessageUtil(super.toXml());
		util.addData("MsgType", "image");
		Map<String, String> map = new HashMap<String, String>();
		map.put("MediaId", this.getMediaId());
		map.put("Title", this.getTitle());
		map.put("Description", this.getDescription());
		util.addData("Video", map);
		util.surroundWith("xml");
		return util.toString();
	}
	
	public static void main(String[] args) {
		MtonsVideoVO vo = new MtonsVideoVO();
		vo.setToUserName("liujiao");
		vo.setFromUserName("majinjian");
		vo.setMediaId("54148484848");
		vo.setTitle("新年祝福");
		vo.setDescription("新年祝福内容");
		System.out.println(vo.toXml());
	}
}
